package com.happy.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.util.Date;
import java.util.List;

/**
 * @Author: Wuzh
 * @Description:
 * @Date Created in 22:24 2021/1/25
 * @return
 */
@TableName ("subject_info")
public class SubjectEntity extends BaseEntity {

    @TableId (value = "subjectId", type = IdType.AUTO)
    private Integer subjectId;
    @TableField ("paperId")
    private Integer paperId;
    @TableField (exist = false)
    private String paperName;

    @TableField ("subjectContent")
    private String subjectContent;
    @TableField ("optionId")
    private Integer optionId;
    @TableField (exist = false)
    private String optionContent;

    @TableField ("categoryId")
    private Integer categoryId;

    @TableField (exist = false)
    private String categoryName;

    @TableField ("createTime")
    private Date createTime;
    @TableField ("changeTime")
    private Date changeTime;
    @TableField ("isUsed")
    private Integer isUsed;

    @TableField (exist = false)
    private List<OptionEntity> optionEntities;
    @TableField (exist = false)
    private AnswerEntity answerEntity;

    public Integer getSubjectId () {
        return subjectId;
    }

    public void setSubjectId (Integer subjectId) {
        this.subjectId = subjectId;
    }

    public Integer getPaperId () {
        return paperId;
    }

    public void setPaperId (Integer paperId) {
        this.paperId = paperId;
    }

    public String getPaperName () {
        return paperName;
    }

    public void setPaperName (String paperName) {
        this.paperName = paperName;
    }

    public Integer getCategoryId () {
        return categoryId;
    }

    public void setCategoryId (Integer categoryId) {
        this.categoryId = categoryId;
    }

    public String getCategoryName () {
        return categoryName;
    }

    public void setCategoryName (String categoryName) {
        this.categoryName = categoryName;
    }

    public String getSubjectContent () {
        return subjectContent;
    }

    public void setSubjectContent (String subjectContent) {
        this.subjectContent = subjectContent;
    }

    public Integer getOptionId () {
        return optionId;
    }

    public void setOptionId (Integer optionId) {
        this.optionId = optionId;
    }

    public String getOptionContent () {
        return optionContent;
    }

    public void setOptionContent (String optionContent) {
        this.optionContent = optionContent;
    }

    public Date getCreateTime () {
        return createTime;
    }

    public void setCreateTime (Date createTime) {
        this.createTime = createTime;
    }

    public Date getChangeTime () {
        return changeTime;
    }

    public void setChangeTime (Date changeTime) {
        this.changeTime = changeTime;
    }

    public Integer getIsUsed () {
        return isUsed;
    }

    public void setIsUsed (Integer isUsed) {
        this.isUsed = isUsed;
    }

    public List<OptionEntity> getOptionEntities () {
        return optionEntities;
    }

    public void setOptionEntities (List<OptionEntity> optionEntities) {
        this.optionEntities = optionEntities;
    }

    public AnswerEntity getAnswerEntity () {
        return answerEntity;
    }

    public void setAnswerEntity (AnswerEntity answerEntity) {
        this.answerEntity = answerEntity;
    }

    @Override
    public String toString () {
        return "SubjectEntity{" +
                "subjectId=" + subjectId +
                ", paperId=" + paperId +
                ", paperName='" + paperName + '\'' +
                ", subjectContent='" + subjectContent + '\'' +
                ", optionId=" + optionId +
                ", optionContent='" + optionContent + '\'' +
                ", categoryId=" + categoryId +
                ", categoryName='" + categoryName + '\'' +
                ", createTime=" + createTime +
                ", changeTime=" + changeTime +
                ", isUsed=" + isUsed +
                ", optionEntities=" + optionEntities +
                ", answerEntity=" + answerEntity +
                '}';
    }
}
